package com.sqx.modules.app.controller;

import com.sqx.common.utils.Result;
import com.sqx.modules.app.entity.UserMoneyDetails;
import com.sqx.modules.app.service.UserMoneyDetailsService;
import com.sqx.modules.sys.entity.SysUserEntity;
import com.sqx.modules.sys.service.SysUserService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.AllArgsConstructor;
import org.apache.shiro.SecurityUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestAttribute;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/Details")
@AllArgsConstructor
@Api(value = "钱包明细", tags = {"钱包明细"})
public class UserMoneyDetailsController {
    @Autowired
    private UserMoneyDetailsService userMoneyDetailsService;


    @ApiOperation("钱包明细")
    @GetMapping("/queryUserMoneyDetails")
    public Result queryUserMoneyDetails(Integer page, Integer limit, UserMoneyDetails userMoneyDetails) {

        return userMoneyDetailsService.queryUserMoneyDetails(page, limit, userMoneyDetails);
    }

    @ApiOperation("钱包明细")
    @GetMapping("/selectUserMoneyDetails")
    public Result selectUserMoneyDetails(Integer page, Integer limit,Long userId, Integer classify) {
        return userMoneyDetailsService.selectUserMoneyDetails(page, limit, userId,classify);
    }

    @ApiOperation("保证金管理")
    @GetMapping(value = "/selectCashDeposit")
    public Result selectCashDeposit(String phone, Integer type, Integer page, Integer limit, Long userId) {
        return userMoneyDetailsService.selectCashDeposit(phone, type, page, limit, userId);
    }

}
